package com.newtouch.avmarketing.mongo.service.impl;

import com.newtouch.avmarketing.mongo.dao.InsurancePolicyRepo;
import com.newtouch.avmarketing.mongo.po.PolicyPo;
import com.newtouch.avmarketing.mongo.service.InsurancePolicyService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
public class InsurancePolicyServiceImpl implements InsurancePolicyService {

    @Resource
    private InsurancePolicyRepo insurancePolicyRepo;

    @Override
    public PolicyPo findPolicy(String policyCode) {
        PolicyPo policyPo = insurancePolicyRepo.findByPolicyCode(policyCode);
        return policyPo;
    }
}
